Add patch to fix python module path in cmake
authorStuart Prescott <stuart@debian.org>
Tue, 18 Feb 2025 08:52:59 +0000 (19:52 +1100)
committerStuart Prescott <stuart@debian.org>
Tue, 18 Feb 2025 08:57:28 +0000 (19:57 +1100)
debian/patches/0010-Fix-python-module-paths-in-CMake.patch [new file with mode: 0644]
debian/patches/series

diff --git a/debian/patches/0010-Fix-python-module-paths-in-CMake.patch b/debian/patches/0010-Fix-python-module-paths-in-CMake.patch
new file mode 100644 (file)
index 0000000..22a1b6d
--- /dev/null
@@ -0,0 +1,28 @@
+From: Stuart Prescott <stuart@debian.org>
+Date: Tue, 18 Feb 2025 00:50:57 +1100
+Subject: Fix python module paths in CMake
+
+---
+ sources/shiboken6/cmake/ShibokenHelpers.cmake | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/sources/shiboken6/cmake/ShibokenHelpers.cmake b/sources/shiboken6/cmake/ShibokenHelpers.cmake
+index 9c47770..fa61aed 100644
+--- a/sources/shiboken6/cmake/ShibokenHelpers.cmake
++++ b/sources/shiboken6/cmake/ShibokenHelpers.cmake
+@@ -125,13 +125,13 @@ macro(shiboken_internal_set_python_site_packages)
+                 if sys.platform == 'win32':
+                     lib_path = sysconfig.get_path('purelib')
+                 else:
+-                    lib_path = sysconfig.get_path('purelib', scheme='posix_prefix')
++                    lib_path = sysconfig.get_path('purelib', scheme='deb_system')
+                 # /home/qt/dev/env
+                 if sys.platform == 'win32':
+                     data_path = sysconfig.get_path('data')
+                 else:
+-                    data_path = sysconfig.get_path('data', scheme='posix_prefix')
++                    data_path = sysconfig.get_path('data', scheme='deb_system')
+                 # /lib/python3.9/site-packages
+                 rel_path = lib_path.replace(data_path, '')
index 4bc22403bee302e6f9ecbe1efdca8d6ca8b35a17..f2aea2b507a89300eea53aec976ef449498aaf0c 100644 (file)
@@ -7,3 +7,4 @@
 0007-XFAIL-a-new-test-failure-with-6.7.2.patch
 0008-XFAIL-smart-smart_pointer.patch
 0009-XFAIL-QtQml-qquickitem_grabToImage.patch
+0010-Fix-python-module-paths-in-CMake.patch